from flask import Flask, render_template
from project.user import bp as userbp
from flask_cors import CORS

# 在创建Flask应用程序之后，添加以下代码来启用CORS
app = Flask(__name__, static_folder='static', template_folder='templates')
CORS(app)

# 注册用户蓝图
app.register_blueprint(userbp)


@app.route('/')
def index():
    return render_template('login.html')


if __name__ == '__main__':
    app.run()
